package Monster;

import MainClass.Game;
import SubClasses.Direction;
import SubClasses.ObjectInBox;
import SubClasses.TypeOfVar;

public abstract class Monster extends ObjectInBox 
{
	public Direction DirectionAxisX;
	public Direction DirectionAxisY; 
	public int Step; 
	public int Quantum;
	public TypeOfVar type;
	public Game game;
	public static int startStep;
	public abstract void UpdateMonstersPosition() ;
	
	protected void createAllPossibleOption(int[] newX, int[] newY) 
	{
		newX[0] = Pos_X + DirectionAxisX.GetValue();
		newY[0] = Pos_Y + DirectionAxisY.GetValue();
		
	
			newX[1] = Pos_X + DirectionAxisX.SwapDir().GetValue();
			newY[1] = Pos_Y + DirectionAxisY.GetValue();
			
			newX[2] = Pos_X + DirectionAxisX.GetValue();
			newY[2] = Pos_Y + DirectionAxisY.SwapDir().GetValue();
			
			newX[3] = Pos_X +  DirectionAxisX.SwapDir().GetValue();
			newY[3] = Pos_Y + DirectionAxisY.SwapDir().GetValue();
	
		
		newX[4] = Pos_X ;
		newY[4] = Pos_Y + DirectionAxisY.GetValue();
		
		newX[5] = Pos_X + DirectionAxisX.GetValue();
		newY[5] = Pos_Y;
		
		newX[6] = Pos_X ;
		newY[6] = Pos_Y + DirectionAxisY.SwapDir().GetValue();
		
		newX[7] = Pos_X +  DirectionAxisX.SwapDir().GetValue();
		newY[7] = Pos_Y;
	}
	
	public Direction NewDirectionAxisX(int i)
	{
		if(i==0 || i==2 || i==4 || i==5 || i==6)
		{
			return  DirectionAxisX;
		}
		else 
		{
			return DirectionAxisX.SwapDir();
		}
	}
	public Direction NewDirectionAxisY(int i)
	{
		if(i==0 || i==1 || i==4 || i==5 || i==7)
		{
			return  DirectionAxisY;
		}
		else 
		{
			return DirectionAxisY.SwapDir();
		}
	}

	
	
		
}
